<%@ page import="java.util.List" %>
<%@ page import="Demo03.User" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<%--
  Created by IntelliJ IDEA.
  User: Wake
  Date: 2019/3/27
  Time: 12:51
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<s:iterator value="#request.list" id="demo">
    <p><s:property value="#demo.username"></s:property> </p>
    <p><s:property value="#demo.password"></s:property> </p>
</s:iterator>

<%
    List<User> list= (List<User>) request.getAttribute("list");
    for (User u : list){
        out.print("<h1>"+u.getUsername()+"</h1>");
    }
%>
</body>
</html>
